package com.jic.order.enums;

public enum OperatorActionEnum {

    USER_CREATE(1, "用户下单"),
    USER_PAY(2, "买家付款"),
    SPLIT(3, "系统拆单"),
    DELIVER(4, "分配交货单"),
    SEND_GOODS(5, "发货"),
    BALE(6, "分配包裹"),
    CLOSED(7, "关闭订单"),
    MODIFY_FLAG(8, "修改标签"),
    AUDIT(9, "审核"),
    MODIFY_ORDER_STATUS(10, "修改订单状态"),
    CANCEL_ORDER(11, "买家取消订单"),
    CONFIRM_RECEIPT(12, "买家确认收货");

    private Integer code;

    private String message;

    OperatorActionEnum(Integer code, String message) {
        this.code = code;
        this.message = message;
    }

    public static OperatorActionEnum getByCode(Integer code) {
        OperatorActionEnum[] values = OperatorActionEnum.values();
        for (OperatorActionEnum value : values) {
            if (value.getCode().equals(code)) {
                return value;
            }
        }
        return null;
    }

    public Integer getCode() {
        return code;
    }

    public void setCode(Integer code) {
        this.code = code;
    }

    public String getMessage() {
        return message;
    }

    public void setMessage(String message) {
        this.message = message;
    }

    }
